﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace MultiAgentLib
{
    public static class Color
    {
        private static ConsoleColor[] _colors = {
                                                        ConsoleColor.Yellow,
                                                        ConsoleColor.Red,
                                                        ConsoleColor.Green,
                                                        ConsoleColor.Magenta,
                                                        ConsoleColor.Cyan,
                                                        ConsoleColor.White
                                                      };
        private static int _index = 0;

        public static ConsoleColor GetColor()
        {
            //If all colors have been used, start from the beginning of the array 
            if (_index >= _colors.Length)
                _index = 0;
            return _colors[_index++];
        }
    }
}
